{include file="public/head"}
<body>
    <div class="layui-card layadmin-header">
        {$breadcrumb|raw}
    </div>
    <div class="layui-fluid">
        <div class="layui-row layui-col-space15">
            <div class="layui-col-md12">
                <div class="layui-card">
                    <div class="layui-card-header">{$title|default=''}</div>
                    <div class="layui-card-body">
                        <form action="{:url('')}" class="layui-form" lay-filter="edit-form" method="post">
                            <div class="layui-form-item">
                                <label class="layui-form-label">图片上传</label>
                                <style>
                                    .layui-upload-img{
                                        margin-right: 10px;
                                        max-width: 200px;
                                        max-height: 200px;
                                        min-width: 100px;
                                        min-height: 100px;
                                    }
                                </style>
                                <div class="layui-input-block">
                                    <div class="layui-upload">
                                        <button type="button" class="layui-btn upload_api" id="upload_upload_img"
                                                data-url='{:url("file/pictureUpload")}'
                                                data-accept="images" data-accept-mime="image/*"
                                                data-exts="jpg|jpeg|gif|png"
                                                data-field="image"
                                                data-check="{:url('file/checkPictureExists')}"
                                                data-id-ext="upload_img"
                                        >图片上传</button>
                                        <div class="layui-progress layui-hide" id="progress_upload_img" lay-filter="progress_upload_img" lay-showPercent="true">
                                            <div class="layui-progress-bar" lay-percent="0%"></div>
                                        </div>
                                        <input type="hidden" name="post[upload_img]" id="upload_input_upload_img" value="{$info.path|default=''}">
                                        <blockquote class="layui-elem-quote layui-quote-nm" style="margin-top: 10px;min-height: 150px;">
                                            <div class="layui-upload-list" id="preview_upload_img">
                                                {notempty name="$info"}
                                                {volist name=":\util\StringUtil::instance()->strToArr($info['path'])" id="vo"}
                                                <img src="{$vo}" alt="" class="layui-upload-img">
                                                {/volist}
                                                {/notempty}
                                            </div>
                                        </blockquote>
                                    </div>
                                    <script id="tpl_upload_img" type="text/html">
                                        <img src="{{d.data.path}}" alt="{{d.data.name}}" class="layui-upload-img">
                                    </script>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>
    {include file="public/script"}
</body>
</html>